home *** CD-ROM | disk | FTP | other *** search
/ C!T ROM 3 / ct-rom iiib.zip / ct-rom iiib / WINDOWS / DIVERSEN / WINE02BX / BG-MOUSE.ELC < prev    next >
Text File  |  1993-03-28  |  6KB  |  72 lines

  1. ;;; compiled by jwz@thalidomide on Thu Jul  2 16:31:44 1992
  2. ;;; from file /u/jwz/emacs19/lisp/packages/bg-mouse.el
  3. ;;; emacs version 19.2.1 Lucid.
  4. ;;; bytecomp version 2.07; 17-jun-92.
  5. ;;; optimization is on.
  6. ;;; this file uses opcodes which do not exist in Emacs18.
  7.  
  8. (if (and (boundp 'emacs-version)
  9.      (or (and (boundp 'epoch::version) epoch::version)
  10.          (string-lessp emacs-version "19")))
  11.     (error "This file was compiled for Emacs19."))
  12.  
  13. (provide 'bg-mouse)
  14. (defvar bg-mouse-fast-select-window nil "\
  15. *Non-nil for mouse hits to select new window, then execute; else just select.")
  16. (byte-code "└┬┬┼╟╔\n╦ ═└ç" [1 bg-button-r 2 bg-button-m bg-button-c 4 bg-button-l 8 bg-in-modeline 16 bg-in-scrollbar 24 bg-in-minibuf 59 semicolon] 1)
  17. (fset 'bg-mouse-report #[(prefix-arg) "└    !ê┬ S└    !├Ñ^┼ S└    !╞ÑZ└╚!╔ª\n╦ \" ═ ╧ !┼ SUë?¡ê╥8SU?¡î?¡ç ╘8SY =¡â ?ë½ä¬ü┘½ä¬ü┘½ä¬ü┘\\\\▌▀\n\\!\"  @Z!A@Z\"¼ä½Éπ !êΣ !êπ!¬¢¼ä½åΣ !¬ìπ !ê%¡äΣ !.ç" [bg-get-tty-num semicolon screen-width 9 screen-mouse-x screen-height 16 screen-mouse-y 99 8 bg-mouse-buttons bg-window-from-x-y bg-mouse-window selected-window bg-cursor-window window-edges edges minibuf-p 3 in-modeline-p 2 in-scrollbar-p same-window-p in-minibuf-p bg-in-minibuf 0 bg-in-modeline bg-in-scrollbar bg-mode-bits lookup-key mouse-map char-to-string bg-command bg-mouse-x bg-mouse-y select-window bg-command-execute bg-mouse-fast-select-window] 6 "\
  18. Read, parse, and execute a BBN BitGraph mouse click.
  19.  
  20. L-- move point             | These apply for mouse click in a window.
  21. --R set mark               | If bg-mouse-fast-select-window is nil,
  22. L-R kill region            | these commands on a nonselected window
  23. -C- move point and yank    | just select that window.
  24. LC- yank-pop           |
  25. -CR or LCR undo           | \"Scroll bar\" is right-hand window column.
  26.  
  27. on modeline:            on \"scroll bar\":    in minibuffer:
  28. L-- scroll-up            line to top        execute-extended-command
  29. --R scroll-down            line to bottom    eval-expression
  30. -C- proportional goto-char  line to middle    suspend-emacs
  31.  
  32. To reinitialize the mouse if the terminal is reset, type ESC : RET" "P"])
  33. (fset 'bg-set-point #[nil "└    \n\"ê├    ëç" [bg-move-point-to-x-y bg-mouse-x bg-mouse-y next-line this-command temporary-goal-column] 3 "\
  34. Move point to location of BitGraph mouse." nil])
  35. (fset 'bg-set-mark #[nil "└ ê┴\n \"ê─ ç" [push-mark bg-move-point-to-x-y bg-mouse-x bg-mouse-y exchange-point-and-mark] 3 "\
  36. Set mark at location of BitGraph mouse." nil])
  37. (fset 'bg-yank #[nil "└    \n\"ê├├ ç" [bg-move-point-to-x-y bg-mouse-x bg-mouse-y yank this-command] 3 "\
  38. Move point to location of BitGraph mouse and yank." "*"])
  39. (fset 'yank-pop-1 #[nil "└┴!ç" [yank-pop 1] 2 nil "*"])
  40. (fset 'bg-yank-or-pop #[nil "┴=½ä┬├!ç─ ç" [last-command yank yank-pop 1 bg-yank] 2 "\
  41. Move point to location of BitGraph mouse and yank or yank-pop.
  42. Do a yank unless last command was a yank, in which case do a yank-pop." "*"])
  43. (byte-code "└└ç" [8388607 bg-most-positive-fixnum] 1)
  44. (fset 'bg-move-by-percentage #[nil "┴U½â┴¬Ü┬  ÑW½è┬ _─ SѬê┬ ─ SÑ_bê┴yê┼ ç" [bg-mouse-x 0 buffer-size bg-most-positive-fixnum window-width what-cursor-position] 3 "\
  45. Go to location in buffer that is the same percentage of the
  46. way through the buffer as the BitGraph mouse's X position in the window." nil])
  47. (fset 'bg-mouse-line-to-top #[nil "└    !ç" [scroll-up bg-mouse-y] 2 "\
  48. Scroll the line pointed to by the BitGraph mouse to the top of the window." nil])
  49. (fset 'bg-mouse-line-to-center #[nil "└    ë┬ [├\\\\\\├Ñ!ç" [scroll-up bg-mouse-y window-height 2] 5 "\
  50. Scroll the line pointed to by the BitGraph mouse to the center 
  51. of the window" nil])
  52. (fset 'bg-mouse-line-to-bottom #[nil "└    ┬├ Z\\!ç" [scroll-up bg-mouse-y 2 window-height] 4 "\
  53. Scroll the line pointed to by the mouse to the bottom of the window." nil])
  54. (fset 'bg-kill-region #[nil "└┴ ┬ \"ç" [kill-region region-beginning region-end] 3 nil "*"])
  55. (fset 'bg-insert-moused-sexp #[nil "è└    \n\"ê├─!êè┼─!ê`)`{)╟!ê╔ ên½à╩ ê¬öè╦uê╠═!?¡â╠╬!)¼ä╧╨!ê╧!êl«ö╠╤!«Å╠╥!½à╠╙!«àè╧╨!))ç" [bg-move-point-to-x-y bg-mouse-x bg-mouse-y forward-sexp 1 backward-sexp moused-text select-window bg-cursor-window delete-horizontal-space indent-according-to-mode -1 looking-at "\\s\"" "[`'\"\\]\\|\\s(" insert-string " " "\\s.\\|\\s)" "'" "\\sw"] 3 "\
  56. Insert a copy of the word (actually sexp) that the mouse is pointing at.
  57. Sexp is inserted into the buffer at point (where the text cursor is).
  58. By gildea 7 Feb 89" nil])
  59. (fset 'bg-get-tty-num #[(term-char) "└┴ ┬Z └Y½ô ┼X½Ä ╞_ \\┴ ┬Zë¬i ┬\\=¼ç╚ ê╔╩!ê *ç" [0 read-char 48 char num 9 10 term-char bg-program-mouse error "Invalid data format in bg-mouse command: mouse reinitialized."] 4 "\
  60. Read from terminal until TERM-CHAR is read, and return intervening number.
  61. If non-numeric not matching TERM-CHAR, reprogram the mouse and signal an error."])
  62. (fset 'bg-move-point-to-x-y #[(x y) "└    !êi┬  ┼V½â S╞ \\\\!*ç" [move-to-window-line y window-hscroll scroll-offset zero-column 0 move-to-column x] 4 "\
  63. Position cursor in window coordinates.
  64. X and Y are 0-based character positions in the window."])
  65. (fset 'bg-window-from-x-y #[(x y) "└ ┴\n─ =¼º A@W¼û╞ 8Y¼Å @W¼ê╚ 8Y½è╔\n!└\n!¬S\n─ =½â┴¬ê\n¼ä─ ¬ü\n*ç" [window-edges nil window edges selected-window y 3 x 2 next-window] 3 "\
  66. Find window corresponding to screen coordinates.
  67. X and Y are 0-based character positions on the screen."])
  68. (byte-code "└┴Mê┬├Mê─!¼â╞ └ç" [bg-command-execute #[(bg-command) "└    !½ä┬    !ç├ ç" [commandp bg-command command-execute ding] 2] bg-program-mouse #[nil "└┴!ç" [send-string-to-terminal ":0;7;;;360;512;9;16;9;16c"] 2] keymapp mouse-map make-keymap] 2)
  69. (fset 'bind-bg-mouse-click #[(click-code function) "└    ┬ ! #ç" [define-key mouse-map char-to-string click-code function] 4 "\
  70. Bind bg-mouse CLICK-CODE to run FUNCTION."])
  71. (byte-code "└    ┬\"ê└ ─\"ê└╞\"ê└     \\╟\"ê└    \\╚\"ê└ \\╔\"ê└     \\\\╔\"ê└\n    \\╦\"ê└\n \\╠\"ê└\n\\═\"ê└    \\╧\"ê└ \\╨\"ê└\\╤\"ê└    \\╙\"ê└ \\╘\"ê└\\╒\"ç" [bind-bg-mouse-click bg-button-l bg-set-point bg-button-m bg-yank bg-button-r bg-set-mark yank-pop-1 bg-kill-region undo bg-in-modeline scroll-up bg-move-by-percentage scroll-down bg-in-scrollbar bg-mouse-line-to-top bg-mouse-line-to-center bg-mouse-line-to-bottom bg-in-minibuf execute-extended-command suspend-emacs eval-expression] 4)
  72.